home *** CD-ROM | disk | FTP | other *** search
- import java.awt.Color;
- import java.awt.Graphics;
- import java.awt.Polygon;
- import java.awt.Rectangle;
- import java.io.DataInputStream;
- import java.io.IOException;
-
- abstract class ColVecItm extends ColObj {
- protected int m_penSz = 1;
- protected int m_penMode;
- protected int m_numSegs;
- protected int m_itemType;
- protected Color m_fillClr;
- protected Color m_frameClr;
- protected Polygon m_poly;
- protected float[] m_ptArryX;
- protected float[] m_ptArryY;
- protected ColGrph m_colGraphicObj;
- public Rectangle m_bounds = new Rectangle();
-
- public void drawPoly(Graphics var1) {
- if (this.m_fillClr != null) {
- if (this.m_colGraphicObj.m_overrideColor != null) {
- var1.setColor(this.m_colGraphicObj.m_overrideColor);
- } else {
- var1.setColor(this.m_fillClr);
- }
-
- var1.fillPolygon(this.m_poly);
- }
-
- if (this.m_frameClr != null) {
- if (this.m_colGraphicObj.m_overrideColor != null) {
- var1.setColor(this.m_colGraphicObj.m_overrideColor);
- } else {
- var1.setColor(this.m_frameClr);
- }
-
- var1.drawPolygon(this.m_poly);
- }
-
- }
-
- public int getType() {
- return this.m_itemType;
- }
-
- public ColVecItm(DataInputStream var1, int var2, ColGrph var3) throws IOException {
- this.m_colGraphicObj = var3;
- if ((var2 & 1) != 0) {
- this.m_fillClr = new Color(var1.readInt());
- }
-
- if ((var2 & 2) != 0) {
- this.m_frameClr = new Color(var1.readInt());
- }
-
- if ((var2 & 4) != 0) {
- this.m_penSz = var1.readInt();
- }
-
- if ((var2 & 64) != 0) {
- this.m_penMode = var1.readInt();
- }
-
- }
- }
-